package com.eastfair.pay.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.eastfair.boot.request.PageParams;
import com.eastfair.boot.service.SuperService;
import com.eastfair.pay.dto.PaymentRecordDTO;
import com.eastfair.pay.dto.PaymentRecordPageQuery;
import com.eastfair.pay.dto.PaymentRecordSaveDTO;
import com.eastfair.pay.dto.PaymentRecordUpdateDTO;
import com.eastfair.pay.entity.PaymentRecord;
import com.eastfair.pay.vo.PaymentRecordVO;

import java.util.List;

/**
 * <p>
 * 业务接口
 * 付款记录
 * </p>
 *
 * @author clm
 * @date 2022-06-08
 */
public interface PaymentRecordService extends SuperService<PaymentRecord> {

    void update(PaymentRecordUpdateDTO paymentRecordUpdateDTO);

    Page<PaymentRecordVO> queryPagePaymentRecord(PageParams<PaymentRecordPageQuery> params);

    List<PaymentRecord> queryList(PaymentRecordDTO paymentRecordDTO);
    public PaymentRecord getRecordByMainno(String mainno);

    void deleteById(Long recordId);

    /**
     * 结算认领
     * @param paymentRecordDTO
     * @return
     */
    Boolean settlementCollect(PaymentRecordDTO paymentRecordDTO);
    /**
     * @Author clm
     * @Description //金额认领
     * @Date 15:20 2023/2/14
     * @Param [paymentRecordDTO]
     * @return com.eastfair.core.base.R<java.lang.Boolean>
     **/
    Boolean amountCollect(PaymentRecordDTO paymentRecordDTO);

    /**
     * 批量保存付款记录
     * @param dtos
     * @return
     */
    void batchSave(List<PaymentRecordSaveDTO> dtos);

    void deleteByMainno(String mainno);
}
